MODEL = s
CC = g++
ARCHIVER = ar
AFLAGS = -r
CFLAGS = -O0 -g3 -Wall -fmessage-length=0 -MMD -MP
RM = rm
RMFLAGS = -f
MKDIR = mkdir
MKDIRFLAGS = -p

MODULES = common \
		  IPC \
	      application \
	      logger

FILES=`for curr_dir in $(MODULES); do find $$curr_dir -name "*.cpp"; done`
#OBJS=`find . -name "*.cpp"|sed 's/.cpp/.o/g'`

all: clean building floor elevator 

sandbox:
	$(CC) $(CFLAGS) $(FILES) sandbox.cpp -o sandbox	
	
building:
	$(CC) $(CFLAGS) $(FILES) building.cpp -o building		
	
floor:
	$(CC) $(CFLAGS) $(FILES) floor.cpp -o floor
	
elevator:
	$(CC) $(CFLAGS) $(FILES) elevator.cpp -o elevator	
	
#Clean
clean:  
	$(RM) $(RMFLAGS) floor building elevator sandbox

